#pragma once

#include "rays.h"

struct SphereStream
{
	SphereStream(int p_block_count) : block_count(p_block_count),
		origins(p_block_count), radii(p_block_count)
	{
	}
	int block_count;
	v3stream origins;
	f32stream radii;
};
struct IntersectRayWithSpheresInfo
{
	in RayStream* __restrict rays;
	in SphereStream* __restrict spheres;
	in int intersection_stream_offset;
	in int ray_blocks_count;
	in int sphere_blocks_count;
	//in int rays_offset; //not used
	//in int spheres_offset; //not used
	in f32stream* debug;

	out RayIntersectionStream* __restrict intersections;
};
void intersect_rays_with_spheres(const IntersectRayWithSpheresInfo& info);